﻿using System;
using Common.Util;
using System.ComponentModel.DataAnnotations.Schema;

namespace Authentication.Model.Model
{
    public partial class ObjectSubstitution
    {
        public string ApplicationKey { get; set; }

        [NotMapped]
        public Guid GuidKey { get { return new Guid(this.ApplicationKey); } }

        public string Id { get; set; }

        public string ObjectId { get; set; }

        public string ObjectNameLocal { get; set; }

        public string ObjectNameEnglish { get; set; }

        public string ParentId { get; set; }

        public int Olevel { get; set; }

        public int OrderId { get; set; }

        public string Active { get; set; }

        [NotMapped]
        public bool IsActive { get { return Active.IsYes(); } }

        public ApplicationObject Object { get; set; }
    }
}
